#include<SDL.h>
#include<SDL_ttf.h>
#include<stdlib.h>
#include<stdio.h>
int main(int argc,char** argv)
{
    SDL_Init(SDL_INIT_EVERYTHING);
    TTF_Init();
    TTF_Font* font=TTF_OpenFont("./data/font.ttf",32);

    SDL_Surface* screen,*image,*text;
    screen=SDL_SetVideoMode(1250,650,32,SDL_SWSURFACE);
    if (screen == NULL)
    {
        printf("Unable to set video mode: %s\n", SDL_GetError());
        return 1;
    }
    bool running=true;
    image=SDL_DisplayFormat(SDL_LoadBMP("Monopoly Board Blank 2.bmp"));
    if (image == NULL)
    {
        printf("Unable to load bitmap: %s\n", SDL_GetError());
        return 1;
    }
    SDL_Color color3={255,255,255};
    text=TTF_RenderText_Solid(font,"HELLO WORLD",color3);
    while(running)
    {
        SDL_Event event;
        while(SDL_PollEvent(&event))
        {

            SDL_BlitSurface(image,NULL,screen,NULL);
            switch(event.type)
            {
            case SDL_QUIT:
                running=false;
                break;
            }
        }
        SDL_BlitSurface(text,NULL,screen,NULL);
        SDL_Flip(screen);
    }
    SDL_FreeSurface(image);
    SDL_FreeSurface(text);
    TTF_Quit();
    SDL_Quit();
    return 0;
}


